const fs = require('fs')

fs.writeFile('./test.txt','this is a test', (err) =>{
    if(err) throw err;
    console.log('testFile created');
})
fs.readFile('./test.txt',(err,data) =>{
    if(err) throw err;
    console.log(data.toString());
})